/*
 * display.h
 *
 */

#ifndef INC_DISPLAY_H_
#define INC_DISPLAY_H_

/**
 * includes
 *
 */
#include "app.h"
#include "led8s595.h"
#include "utils.h"

/**
 * typedefs
 *
 */
typedef enum {

	DISPLAY_INIT = 1,
	DISPLAY_MAIN = 200,
	DISPLAY_FUNCTION = 300,
	DISPLAY_PARAM,
	DISPLAY_SET,
	DISPLAY_SAVE = 999,
	DISPLAY_END
} Display_TypeDef;

typedef enum {
	REGISTER_C = 1,
	REGISTER_DI,
	REGISTER_HR,
	REGISTER_IR,
	REGISTER_F,
	REGISTER_END
} Function_TypeDef;

typedef enum {

	D_START = 0,
	D_TEMP1,
	D_HUM1,
	D_TEMP2,
	D_HUM2,
	D_DOOR1,
	D_DOOR2,
	D_HEIGHT1,
	D_HEIGHT2,
	D_HEIGHT3,
	D_END

} Data_TypeDef;

typedef enum {

	P_START = 0,
	P_INTERVAL,
	P_HEIGHT,
	P_H_TIME,
	P_DATE = 6,
	P_TIME = 9,
	P_NAME = 12,
	P_NUMBER = 14,
	P_CLEAR = 16,
	P_END

} Param_TypeDef;

/**
 * functions
 *
 */
void displaySetup(void);
void displayLoop(void);
void displayTask1ms(void);

#endif /* INC_DISPLAY_H_ */
